from typing import Generic, Dict, List
from abc import ABC, abstractmethod
from TypeDefinition import V, D


class Constraint(Generic[V, D], ABC):
    def __init__(self, variables: List[V]) -> None:
        self.variables = variables

    @abstractmethod
    def satisfied(self, assignment: Dict[V, D]) -> bool:
        pass

